Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add to_title helper func #175

Merged
merged 2 commits into from
Oct 21, 2024

Conversation

dwisiswant0
Copy link
Member

Close #51

Signed-off-by: Dwi Siswanto <git@dw1.io>
Signed-off-by: Dwi Siswanto <git@dw1.io>
Copy link
Member

@Mzack9999 Mzack9999 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Future proposal: what do you think about a unique function for languages formatting, accepting multiple optional arguments, something like:

format("string", "language", title | lower | upper | camel_case | snake_case | ...)

@dwisiswant0
Copy link
Member Author

dwisiswant0 commented Oct 7, 2024

Future proposal: what do you think about a unique function for languages formatting, accepting multiple optional arguments, something like:

format("string", "language", title | lower | upper | camel_case | snake_case | ...)

I prefer having these "case converter" funcs as separate DSLs so they can be chained easily with other converters[?], like to_slug(to_title(s)), instead of convert_case(s, caseType) or the format func you proposed.

https://github.com/chanced/caps

@dwisiswant0
Copy link
Member Author

dwisiswant0 commented Oct 7, 2024

Unless caseTypes is variadic, then converts based on index, I'm on board with that.

@dwisiswant0
Copy link
Member Author

Can we merge it, @ehsandeep?

@ehsandeep ehsandeep merged commit d5dce1e into main Oct 21, 2024
5 checks passed
@ehsandeep ehsandeep deleted the dwisiswant0/feat/add-to-title-helper-func branch October 21, 2024 12:08
@ehsandeep
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add to_title helper function
3 participants